package com.aisile.admin;

import com.aisile.model.admin.dtos.ChannelDto;
import com.aisile.model.admin.pojos.AdChannel;
import com.aisile.model.common.dtos.ResponseResult;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiImplicitParam;
import io.swagger.annotations.ApiImplicitParams;
import io.swagger.annotations.ApiOperation;

import java.util.List;

/**
 * @Auther:yry
 * @Date:2024/7/9 0009
 * @VERSON:1.0 定义以后 我的controller 具备什么能力
 */
@Api(value = "频道管理",tags = "AdChannelControllerApi",description = "频道管理Api文档")
public interface AdChannelControllerApi {

    // 定义接口的时候 需要考虑什么事情？ 入参和出参
    // 只要这个接口 是前端使用的  就返回ResponseResult
    // 如果这个接口是feign 调用 随便怎么方便怎么来
    @ApiOperation("分页查询")
    public ResponseResult findByPage(ChannelDto dto);

    /**
     * doc 文档注释
     * @param adChannel
     * @return
     */
    @ApiOperation("添加频道信息")
    public ResponseResult saveChannel(AdChannel adChannel);

    /**
     *
     * @param id
     * @return
     */
    @ApiOperation("根据id查询频道详情")
    @ApiImplicitParam(name = "id",value = "频道id",required = false,readOnly = true,defaultValue = "1")
    public ResponseResult getOne(Integer id);


    @ApiOperation("修改频道信息")
    @ApiImplicitParams({
            @ApiImplicitParam(name = "id",value = "频道id",required = false,readOnly = true,defaultValue = "1"),
            @ApiImplicitParam(name = "adChannel",value = "频道对象",dataType = "AdChannel",required = true)
    })
    public ResponseResult updateChannel(Integer id,AdChannel adChannel);


}
